package com.zhuang.chapter18;

public class IntSort {
	public void sort(int a, int b) {
		if (a > b) {
			System.out.printf("%d,%d", a, b);
		} else {
			System.out.printf("%d,%d", b, a);
		}
	}

	public void sort(int a, int b, int c) {
		int t;
		if (a < b) {
			t = a;
			a = b;
			b = t;
		} else if (b < c) {
			t = b;
			b = c;
			c = t;
		} else if (a < b) {
			t = a;
			a = b;
			b = t;
		}
		System.out.printf("%d,%d,%d", a, b, c);
	}
}
